using System;
using System.Collections.Generic;
using System.Text;

namespace Sio.Mdm.Server
{
    /// <summary>
    /// Attribute for marking service classes
    /// </summary>
    [AttributeUsage(AttributeTargets.Class, AllowMultiple=false, Inherited=true)]
    public class ServiceAttribute : Attribute
    {
        #region Construction
        public ServiceAttribute()
        {
        } 
        #endregion

        #region Properties

        #region Public

        #region Name
        private string _name;
        /// <summary>
        /// Get or set name of the service
        /// </summary>
        public string Name
        {
            get
            {
                return _name;
            }
            set
            {
                _name = value;
            }
        }
        #endregion

        #region DefaultInterface
        private Type _interface;
        /// <summary>
        /// Get or set interface that service implements. If this is not explicitly
        /// defined then the first interface found is used as default
        /// </summary>
        public Type DefaultInterface
        {
            get
            {
                return _interface;
            }
            set
            {
                _interface = value;
            }
        }
        #endregion

        #endregion

        #endregion
    }
}
